package com.damai.action.factories;

import java.lang.reflect.Method;
import java.util.List;

import com.citywithincity.utils.CachedClassUtil;
import com.damai.action.IAction;
import com.damai.action.IActionFactory;
import com.damai.action.RawAction;
import com.damai.action.aop.Interceptor;

import javassist.ClassPool;

public class RawActionFactory implements IActionFactory {

	@Override
	public IAction createAction( ClassPool classPool, Class<?> controllerClass, Method method, String key, List<Interceptor> interceptors) {
		Object controller = CachedClassUtil.newController(controllerClass);
		return new RawAction(key, method, controller);
	}

}
